\hypertarget{earth2wireframe_8c}{}\section{earth/earth2wireframe.c File Reference}
\label{earth2wireframe_8c}\index{earth/earth2wireframe.\+c@{earth/earth2wireframe.\+c}}


Convert Earth wireframe in Lon, Lat pairs into X,Y,Z integer fixed point Each group (a set of Lon, Lat pairs) is separated by one or more blank lines, \# are comments and ignored.  


{\ttfamily \#include $<$stdio.\+h$>$}\\*
{\ttfamily \#include $<$stdlib.\+h$>$}\\*
{\ttfamily \#include $<$string.\+h$>$}\\*
{\ttfamily \#include $<$math.\+h$>$}\\*
{\ttfamily \#include $<$time.\+h$>$}\\*
{\ttfamily \#include $<$unistd.\+h$>$}\\*
{\ttfamily \#include $<$libgen.\+h$>$}\\*
{\ttfamily \#include \char`\"{}../wire/wire\+\_\+types.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}../cordic/cordic2c\+\_\+inc.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}../cordic/cordic.\+h\char`\"{}}\\*
\subsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\#define \hyperlink{earth2wireframe_8c_ab946e2e7f7679350627acfded8e2658b}{T\+E\+ST}
\item 
\#define \hyperlink{earth2wireframe_8c_ad0fe97585b8891f5e4f2b9a6426330a4}{M\+E\+M\+S\+P\+A\+CE}
\end{DoxyCompactItemize}
\subsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
typedef unsigned char \hyperlink{earth2wireframe_8c_aba7bc1797add20fe3efdf37ced1182c5}{uint8\+\_\+t}
\item 
typedef signed char \hyperlink{earth2wireframe_8c_aef44329758059c91c76d334e8fc09700}{int8\+\_\+t}
\item 
typedef unsigned short \hyperlink{earth2wireframe_8c_a273cf69d639a59973b6019625df33e30}{uint16\+\_\+t}
\item 
typedef unsigned int \hyperlink{earth2wireframe_8c_a435d1572bf3f880d55459d9805097f62}{uint32\+\_\+t}
\item 
typedef int \hyperlink{earth2wireframe_8c_a32f2e37ee053cf2ce8ca28d1f74630e5}{int32\+\_\+t}
\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
double \hyperlink{earth2wireframe_8c_a8012f8bd66798ffbdd27462c9f593a54}{deg2rad} (double deg)
\begin{DoxyCompactList}\small\item\em Convert of Radians. \end{DoxyCompactList}\item 
char $\ast$ \hyperlink{earth2wireframe_8c_a4bc7ca5cbf08837c18c54b7a754d7900}{get\+\_\+date} ()
\begin{DoxyCompactList}\small\item\em Get the current date in a string. \end{DoxyCompactList}\item 
int \hyperlink{earth2wireframe_8c_a0ddf1224851353fc92bfbff6f499fa97}{main} (int argc, char $\ast$argv\mbox{[}$\,$\mbox{]})
\begin{DoxyCompactList}\small\item\em Convert earth wireframe data to C structure Usage\+: s -\/f source -\/o result~\newline
",argv\mbox{[}0\mbox{]}); -\/f source is the lot,lat dataset pairs -\/o result is the con=verted file into C\+O\+R\+D\+IC fixed point format. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Convert Earth wireframe in Lon, Lat pairs into X,Y,Z integer fixed point Each group (a set of Lon, Lat pairs) is separated by one or more blank lines, \# are comments and ignored. 

\begin{DoxyParagraph}{Copyright \copyright{} 2015 Mike Gore, G\+PL License}

\end{DoxyParagraph}
\begin{DoxyParagraph}{You are free to use this code under the terms of G\+PL}
please retain a copy of this notice in any code you use it in.
\end{DoxyParagraph}
This is free software\+: you can redistribute it and/or modify it under the terms of the G\+NU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This software is distributed in the hope that it will be useful, but W\+I\+T\+H\+O\+UT A\+NY W\+A\+R\+R\+A\+N\+TY; without even the implied warranty of M\+E\+R\+C\+H\+A\+N\+T\+A\+B\+I\+L\+I\+TY or F\+I\+T\+N\+E\+SS F\+OR A P\+A\+R\+T\+I\+C\+U\+L\+AR P\+U\+R\+P\+O\+SE. See the G\+NU General Public License for more details.

You should have received a copy of the G\+NU General Public License along with this program. If not, see \href{http://www.gnu.org/licenses/}{\tt http\+://www.\+gnu.\+org/licenses/}. 

\subsection{Macro Definition Documentation}
\index{earth2wireframe.\+c@{earth2wireframe.\+c}!M\+E\+M\+S\+P\+A\+CE@{M\+E\+M\+S\+P\+A\+CE}}
\index{M\+E\+M\+S\+P\+A\+CE@{M\+E\+M\+S\+P\+A\+CE}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{M\+E\+M\+S\+P\+A\+CE}{MEMSPACE}}]{\setlength{\rightskip}{0pt plus 5cm}\#define M\+E\+M\+S\+P\+A\+CE}\hypertarget{earth2wireframe_8c_ad0fe97585b8891f5e4f2b9a6426330a4}{}\label{earth2wireframe_8c_ad0fe97585b8891f5e4f2b9a6426330a4}


Definition at line 45 of file earth2wireframe.\+c.

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!T\+E\+ST@{T\+E\+ST}}
\index{T\+E\+ST@{T\+E\+ST}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{T\+E\+ST}{TEST}}]{\setlength{\rightskip}{0pt plus 5cm}\#define T\+E\+ST}\hypertarget{earth2wireframe_8c_ab946e2e7f7679350627acfded8e2658b}{}\label{earth2wireframe_8c_ab946e2e7f7679350627acfded8e2658b}


Definition at line 38 of file earth2wireframe.\+c.



\subsection{Typedef Documentation}
\index{earth2wireframe.\+c@{earth2wireframe.\+c}!int32\+\_\+t@{int32\+\_\+t}}
\index{int32\+\_\+t@{int32\+\_\+t}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{int32\+\_\+t}{int32_t}}]{\setlength{\rightskip}{0pt plus 5cm}typedef int {\bf int32\+\_\+t}}\hypertarget{earth2wireframe_8c_a32f2e37ee053cf2ce8ca28d1f74630e5}{}\label{earth2wireframe_8c_a32f2e37ee053cf2ce8ca28d1f74630e5}


Definition at line 43 of file earth2wireframe.\+c.

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!int8\+\_\+t@{int8\+\_\+t}}
\index{int8\+\_\+t@{int8\+\_\+t}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{int8\+\_\+t}{int8_t}}]{\setlength{\rightskip}{0pt plus 5cm}typedef signed char {\bf int8\+\_\+t}}\hypertarget{earth2wireframe_8c_aef44329758059c91c76d334e8fc09700}{}\label{earth2wireframe_8c_aef44329758059c91c76d334e8fc09700}


Definition at line 40 of file earth2wireframe.\+c.

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!uint16\+\_\+t@{uint16\+\_\+t}}
\index{uint16\+\_\+t@{uint16\+\_\+t}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{uint16\+\_\+t}{uint16_t}}]{\setlength{\rightskip}{0pt plus 5cm}typedef unsigned short {\bf uint16\+\_\+t}}\hypertarget{earth2wireframe_8c_a273cf69d639a59973b6019625df33e30}{}\label{earth2wireframe_8c_a273cf69d639a59973b6019625df33e30}


Definition at line 41 of file earth2wireframe.\+c.

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!uint32\+\_\+t@{uint32\+\_\+t}}
\index{uint32\+\_\+t@{uint32\+\_\+t}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{uint32\+\_\+t}{uint32_t}}]{\setlength{\rightskip}{0pt plus 5cm}typedef unsigned int {\bf uint32\+\_\+t}}\hypertarget{earth2wireframe_8c_a435d1572bf3f880d55459d9805097f62}{}\label{earth2wireframe_8c_a435d1572bf3f880d55459d9805097f62}


Definition at line 42 of file earth2wireframe.\+c.

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!uint8\+\_\+t@{uint8\+\_\+t}}
\index{uint8\+\_\+t@{uint8\+\_\+t}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{uint8\+\_\+t}{uint8_t}}]{\setlength{\rightskip}{0pt plus 5cm}typedef unsigned char {\bf uint8\+\_\+t}}\hypertarget{earth2wireframe_8c_aba7bc1797add20fe3efdf37ced1182c5}{}\label{earth2wireframe_8c_aba7bc1797add20fe3efdf37ced1182c5}


Definition at line 39 of file earth2wireframe.\+c.



\subsection{Function Documentation}
\index{earth2wireframe.\+c@{earth2wireframe.\+c}!deg2rad@{deg2rad}}
\index{deg2rad@{deg2rad}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{deg2rad(double deg)}{deg2rad(double deg)}}]{\setlength{\rightskip}{0pt plus 5cm}double deg2rad (
\begin{DoxyParamCaption}
\item[{double}]{deg}
\end{DoxyParamCaption}
)}\hypertarget{earth2wireframe_8c_a8012f8bd66798ffbdd27462c9f593a54}{}\label{earth2wireframe_8c_a8012f8bd66798ffbdd27462c9f593a54}


Convert of Radians. 

Convert Degrees to Rads.


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em deg} & degrees \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
radians 
\end{DoxyReturn}


Definition at line 53 of file earth2wireframe.\+c.



Referenced by main().

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!get\+\_\+date@{get\+\_\+date}}
\index{get\+\_\+date@{get\+\_\+date}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{get\+\_\+date()}{get_date()}}]{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ get\+\_\+date (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}\hypertarget{earth2wireframe_8c_a4bc7ca5cbf08837c18c54b7a754d7900}{}\label{earth2wireframe_8c_a4bc7ca5cbf08837c18c54b7a754d7900}


Get the current date in a string. 

\begin{DoxyReturn}{Returns}
void 
\end{DoxyReturn}


Definition at line 60 of file earth2wireframe.\+c.



Referenced by main().

\index{earth2wireframe.\+c@{earth2wireframe.\+c}!main@{main}}
\index{main@{main}!earth2wireframe.\+c@{earth2wireframe.\+c}}
\subsubsection[{\texorpdfstring{main(int argc, char $\ast$argv[])}{main(int argc, char *argv[])}}]{\setlength{\rightskip}{0pt plus 5cm}int main (
\begin{DoxyParamCaption}
\item[{int}]{argc, }
\item[{char $\ast$}]{argv\mbox{[}$\,$\mbox{]}}
\end{DoxyParamCaption}
)}\hypertarget{earth2wireframe_8c_a0ddf1224851353fc92bfbff6f499fa97}{}\label{earth2wireframe_8c_a0ddf1224851353fc92bfbff6f499fa97}


Convert earth wireframe data to C structure Usage\+: s -\/f source -\/o result~\newline
",argv\mbox{[}0\mbox{]}); -\/f source is the lot,lat dataset pairs -\/o result is the con=verted file into C\+O\+R\+D\+IC fixed point format. 



Definition at line 77 of file earth2wireframe.\+c.

